extends Control


func _ready():
	$"当前回合".visible = false
	$"回合结束".visible = false


func _on_回合结束_pressed():
	ObjectManager.soundManager.play(SoundType.button_click)
	var obj = {"username":ObjectManager.gameManager.me_player.username}
	WebSocketManager.sendObj(true,"turnOver",obj)
	$"..".closeAll()

func refresh(player:Player):
	if (player.is_me):
		$"当前回合".visible = false
		$"回合结束".visible = true
	else:
		$"当前回合".visible = true
		$"当前回合/小子图片".self_modulate = player.color
		$"回合结束".visible = false
	$"../回合时间/AnimationPlayer".play("默认")
